#include <stdio.h>
#include <math.h>

//narcissistic number
int main(){
    int count = 0;
    for(int i = 0; i < 1000; i++){
        if(i >= 100){
            int unit = i % 10;
            int decade = (i % 100) / 10;
            int hundred = i / 100;
            if(pow(unit,3) + pow(decade,3) + pow(hundred,3) == i){
                count ++;
                printf("One of narcissistic numbers is %d.\n", i);
            }
        }
    }

    printf("The total is %d.\n", count);

    return 0;

}